﻿
@{
    ViewBag.Title = Resources.WebStringsWeb.WebTitle;
    Layout = "~/Views/Shared/_LayoutMobile.cshtml";
}

@section css {
    <style>
        .IsException {
            color: red;
        }

        .IsNormal {
            color: blue;
        }

        .mui-bar ~ .mui-content .mui-scroll-wrapper {
            top: 44px;
            height: auto;
        }
    </style>
}
<header class="mui-bar mui-bar-nav">
    <a class="mui-icon mui-icon-left-nav mui-pull-left" href="MSafetyCostRecordList"></a>
    <h1 class="mui-title" style="color:white;">安全费用使用申请详细</h1>
</header>
<div class="mui-content" ng-cloak ng-controller="SafetyCostController" ng-init="
     Id='@(Request.QueryString["Id"].IsEmpty() ? "" : Request.QueryString["Id"])';
     MGetSafetyCostApplyDetail(Id);
     GetSafetyFormFile(Id);
     ApproveModel.FormId=Id;
     ApproveModel.Type=2;
     GetOperateLog(Id);
     ">
    <form class="mui-input-group">
        <div class="mui-input-row">
            <label>部门</label>
            <input type="text" ng-model="CostDetail.DepartmentName" disabled />
        </div>
        <div class="mui-input-row">
            <label>申请人</label>
            <input type="text" ng-model="CostDetail.CreateUserName" disabled />
        </div>
        <div class="mui-input-row">
            <label>申请时间</label>
            <input type="text" value="{{CostDetail.ApplyDate|JSONDate:'yyyy-MM-dd'}}" disabled />
        </div>
        <div class="mui-input-row">
            <label>总金额</label>
            <input type="text" value="{{CostDetail.TotalAmount}}" disabled />
        </div>
        <div class="mui-input-row">
            <label>状态</label>
            <input type="text" value="{{CostDetail.StatusName}}" disabled />
        </div>
    </form>
    <div class="title">
        申请项目：{{CostDetail.ApplyItems.length}}
    </div>
    <ul class="mui-table-view">
        <li class="mui-table-view-cell" ng-repeat="a in CostDetail.ApplyItems">
            <p>范围：{{a.RangeModel.Title}}.{{a.RangeModel.Content}}</p>
            <p>事由：{{a.Option}}</p>
            <p>金额：<span style="color:red;">{{a.Amount}} {{a.Amount|TransCurrency}}</span></p>
            <p ng-show="a.Remark!=null && a.Remark!=''">备注：{{a.Remark}}</p>
        </li>
    </ul>
    <div class="title">
        附件：{{FileList.length}}
    </div>
    <ul class="mui-table-view">
        <li class="mui-table-view-cell" ng-repeat="f in FileList"><a style="display:block;" ng-href="../Download/DownloadFile?FileId={{f.FileId}}">{{f.FileName}}</a></li>
    </ul>
    <div style="height:100px;"></div>
</div>
@section js{
    <script src="~/Assets/js/pg/SafetyCost.js?v=@DateTime.Now.ToString("yyyyMMddHHmm")"></script>

    <script>
        mui.init({
            swipeBack: false,
            keyEventBind: {
                backbutton: false  //关闭back按键监听
            }
        });
    </script>
}
